package com.gma.userprofile.util

import org.apache.spark.sql.SparkSession

object SparkUtil {

  def getSparkSession: SparkSession = {
    //1、创建spark sql环境
    val spark: SparkSession = SparkSession.builder()
      //.master("local")
      .appName("UserProfileSex")
      .enableHiveSupport() //开启hive的元数据支持
      .getOrCreate()

    spark
  }
}
